TINYXML_USE_STL := NO
#
# 'make depend' uses makedepend to automatically generate dependencies 
#               (dependencies are added to end of Makefile)
# 'make'        build executable file 'mycc'
# 'make clean'  removes all .o and executable files
#

# define the C compiler to use
CC = g++

# define any compile-time flags
CFLAGS = -W -Wall -ansi -pedantic

# define any directories containing header files other than /usr/include
#
INCLUDES =

# define library paths in addition to /usr/lib
#   if I wanted to include libraries not in /usr/lib I'd specify
#   their path using -Lpath, something like:
LFLAGS = 

# define any libraries to link into executable:
#   if I want to link in libraries (libx.so or libx.a) I use the -llibname 
#   option, something like (this will link in libmylib.so and libm.so:
LIBS = -ltinyxml

# define the C source files
SRCS = main.cpp Case.cpp Porte.cpp Arbre.cpp Eau.cpp Mur.cpp Plaine.cpp Table.cpp Console.cpp Vue.cpp Map.cpp

# define the C object files 
#
# This uses Suffix Replacement within a macro:
#   $(name:string1=string2)
#         For each word in 'name' replace 'string1' with 'string2'
# Below we are replacing the suffix .c of all words in the macro SRCS
# with the .o suffix
#
OBJS = $(SRCS:.cpp=.o)

# define the executable file 
MAIN = test

#
# The following part of the makefile is generic; it can be used to 
# build any executable just by changing the definitions above and by
# deleting dependencies appended to the file from 'make depend'
#

.PHONY: depend clean

all:	$(MAIN)
	@echo  Simple compiler named mycc has been compiled

$(MAIN): $(OBJS) 
	$(CC) $(CFLAGS) $(INCLUDES) -o $(MAIN) $(OBJS) $(LFLAGS) $(LIBS)

# this is a suffix replacement rule for building .o's from .c's
# it uses automatic variables $<: the name of the prerequisite of
# the rule(a .c file) and $@: the name of the target of the rule (a .o file) 
# (see the gnu make manual section about automatic variables)
.c.o:
	$(CC) $(CFLAGS) $(INCLUDES) -c $<  -o $@ 

clean:
	$(RM) *.o *~ $(MAIN)

depend: $(SRCS)
	makedepend *.cpp $^
	
# DO NOT DELETE

Arbre.o: Arbre.h Case.h
Case.o: Case.h
Console.o: Console.h Vue.h Map.h /usr/include/stdio.h /usr/include/features.h
Console.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
Console.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
Console.o: Table.h
Eau.o: Eau.h Case.h
Map.o: Map.h /usr/include/stdio.h /usr/include/features.h
Map.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
Map.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
Map.o: Table.h
Mur.o: Mur.h Case.h
Plaine.o: Plaine.h Case.h
Porte.o: Porte.h Case.h
Table.o: Table.h Case.h
Vue.o: Vue.h Map.h /usr/include/stdio.h /usr/include/features.h
Vue.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
Vue.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
Vue.o: Table.h
main.o: Map.h /usr/include/stdio.h /usr/include/features.h
main.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
main.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
main.o: Table.h Vue.h Console.h
xmltest.o: /usr/include/stdio.h /usr/include/features.h /usr/include/libio.h
xmltest.o: /usr/include/_G_config.h /usr/include/wchar.h
xmltest.o: /usr/include/xlocale.h
main.o: Map.h /usr/include/stdio.h /usr/include/features.h
main.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
main.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
main.o: Table.h Vue.h Console.h
Case.o: Case.h
Porte.o: Porte.h Case.h
Arbre.o: Arbre.h Case.h
Eau.o: Eau.h Case.h
Mur.o: Mur.h Case.h
Plaine.o: Plaine.h Case.h
Table.o: Table.h Case.h
Console.o: Console.h Vue.h Map.h /usr/include/stdio.h /usr/include/features.h
Console.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
Console.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
Console.o: Table.h
Vue.o: Vue.h Map.h /usr/include/stdio.h /usr/include/features.h
Vue.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
Vue.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
Vue.o: Table.h
Map.o: Map.h /usr/include/stdio.h /usr/include/features.h
Map.o: /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h
Map.o: /usr/include/xlocale.h Case.h Plaine.h Eau.h Porte.h Mur.h Arbre.h
Map.o: Table.h
